<template>
  <el-container class="absolute w-full h-full">
    <el-aside class="h-full">
      <el-menu
        class="h-full border-0"
        text-color="#D1D5DB"
        background-color="transparent"
        active-text-color="#FCD34D"
        :default-active="router.currentRoute.value.fullPath"
        router
      >
        <el-menu-item
          v-for="(item, index) in list"
          :key="index"
          :index="item.index"
        >
          {{ item.name }}
        </el-menu-item>
      </el-menu>
    </el-aside>
    <el-main class="h-full p-0 relative overflow-hidden">
      <router-view />
    </el-main>
  </el-container>
</template>

<script setup>
import router from "../router/index";

defineProps({
  list: Array,
});
</script>
